Copyright (C) 2018 Ariadne Devos

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/k>.

# Preparing patches for upstream

## Bug tracking

If the patch fixes a bug, remove the description of the bug from HACKING and
README. If you found a bug, add a description to README and HACKING.

Add the following lines to the end of the commit message where appropriate:

> Discover-Bug: $BUGID
> Fix-Bug: $BUGID
> Partially-Fix-Bug: $BUGID

If you find a bug, consider writing a test case to detect it.

## Test

If the patch implements a new feature, try to write a test case. A simplistic,
limited test case is better than none at all. Information on writing test cases
is in testing.md

> make test

## Copyright tracking

If you create a new source or documentation file, let it begin with a copyright
and license statement. The license should be GPL-3+, unless you have a good
reason (judged by myself) to do otherwise. For the GPL-3+, this would look like

> support frobnication of BazFoo instruments
> Copyright (C) year BazFoo
>
> This program is free software: you can redistribute it and/or modify
> it under the terms of the GNU General Public License as published by
> the Free Software Foundation, either version 3 of the License, or
> (at your option) any later version.
>
> This program is distributed in the hope that it will be useful,
> but WITHOUT ANY WARRANTY; without even the implied warranty of
> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> GNU General Public License for more details.
>
> You should have received a copy of the GNU General Public License
> along with this program.  If not, see <http://www.gnu.org/licenses/>.

If the source code is copied from another source, keep the copyright and
license statement intact (if it wasn't in the file itself, create a file
LEGAL in the same directory and state the license, copyright (if available),
source and version). If your changes, if any, were significant, and the license
is lax, I might ask you to consider releasing it under the GPL-3+. You can
choose either way.

If you change your name at some point in the future, you can then send an email
requesting to update the source files. Keep in mind however, that lco's git
repository is public and therefore non-rewritable, so word may get around.

You need not to assign copyright. You do, however, have to certify the
Developer's Certificate of Origin 1.1. You do not have to make a legal
signature, you only have to agree and add the following line to the end of the
commit message:

> Signed-off-by: Your name <e@mail>

A copy of that document is named DCO.

## Communication by email

Attach a git bundle containing your changes.

> git bundle create attach.bundle origin/master..topic

Emails should be send to the current maintainer (see contact.md). Prefix the
message subject with [PATCH]. Only text please; disable HTML. Respect the Code
of Conduct (file: code-of-conduct.md). Keep in mind you name and email address
will become part of the public record.

The patch emails typically follow this format:

> Problem
>
> What must be changed
>
> Description of the patch
>
> References
>
> ---
> Signature (name, GPG/PGP fingerprint, email, homepage ...)
> [Public-mailing-list-OK] if the message may appear on public mailing lists
